home *** CD-ROM | disk | FTP | other *** search
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
-
- //------------------------------------------------------------------------------------------------------
- //- Static parameters
- //------------------------------------------------------------------------------------------------------
-
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
-
- struct CVertexShaderShadowInput
- {
- float4 Position : POSITION;
- };
-
- //------------------------------------------------------------------------------------------------------
-
- struct CVertexShaderShadowOutput
- {
- float4 Position : POSITION;
- };
-
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
-
- CVertexShaderShadowOutput ShadowPass (const CVertexShaderShadowInput input);
-
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
-
- CVertexShaderShadowOutput ShadowPass (const CVertexShaderShadowInput input)
- {
- CVertexShaderShadowOutput output;
-
- // output position into world+view+projection space
- output.Position = mul (input.Position,WorldCameraProjection);
-
- return output;
- }
-
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
-
- technique tech_shadow
- <
- int Priority = 1;
- int TechniqueIndex = 0;
- int DeviceType = HWSHADER_ONLY;
- int LightingType = INTEGRATED_LIGHTING;
- string RenderingType = "Shadow";
- >
- {
- pass pass1
- {
- CullMode = CW;
- ZEnable = true;
- ZFunc = LESSEQUAL;
-
- ZWriteEnable = true;
- AlphaBlendEnable = false;
- AlphaTestEnable = false;
- FogEnable = false;
-
- VertexShader = compile vs_1_1 ShadowPass();
-
- PixelShaderConstant[0] = {0.0f,0.0f,0.0f,1.0f};
-
- PixelShader =
- asm
- {
- ps_1_1
-
- mov r0,c0
- };
- }
- }
-
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------
- //------------------------------------------------------------------------------------------------------